package org.example.project_12.entity;

import lombok.*;
import java.time.LocalDateTime;

@Data
@NoArgsConstructor
@AllArgsConstructor
@Builder
public class Favorite {
    
    private Long id;
    
    /**
     * 用户ID
     */
    private Long userId;
    
    /**
     * 文档ID
     */
    private Long documentId;
    
    /**
     * 收藏时间
     */
    private LocalDateTime createdAt;
    
    public void onCreate() {
        this.createdAt = LocalDateTime.now();
    }
} 